package com.antdesignbackend.backend.service.impl;

import com.antdesignbackend.backend.entity.ShopCart;
import com.antdesignbackend.backend.entity.entityVo.ShopCartVo;
import com.antdesignbackend.backend.mapper.ShopCartMapper;
import com.antdesignbackend.backend.service.ShopCartService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ShopCartServiceImpl extends ServiceImpl<ShopCartMapper, ShopCart> implements ShopCartService {
    @Autowired
    private ShopCartMapper shopCartMapper;

    @Override
    public List<ShopCartVo> search(QueryWrapper<ShopCartVo> queryWrapper, Page<ShopCartVo> page) {
        return shopCartMapper.search(queryWrapper, page);
    }
    @Override
    public Integer count(QueryWrapper<ShopCartVo> queryWrapper) {
        return shopCartMapper.count(queryWrapper);
    }
}
